<template>
  <el-card shadow="never" body-style="padding: 8px 16px 0; background-color: rgb(249, 249, 249)">
    <div class="edu-auto-row edu-info-list">
      <div class="edu-auto-col">
        <div class="edu-auto-label">方案名称：</div>
        <div class="edu-auto-content">
          <el-button type="text" @click="preview">{{ content.name }}</el-button>
        </div>
      </div>
      <div class="edu-auto-col">
        <div class="edu-auto-label">年级：</div>
        <div class="edu-auto-content">{{ content.grade }}</div>
      </div>
      <div class="edu-auto-col">
        <div class="edu-auto-label">学院：</div>
        <div class="edu-auto-content">{{ content.faculty }}</div>
      </div>
      <div class="edu-auto-col">
        <div class="edu-auto-label">专业：</div>
        <div class="edu-auto-content">{{ content.major }}</div>
      </div>
      <div class="edu-auto-col">
        <div class="edu-auto-label">培养层次：</div>
        <div class="edu-auto-content">{{ content.trainingLevel }}</div>
      </div>
      <div class="edu-auto-col">
        <div class="edu-auto-label">学位类型：</div>
        <div class="edu-auto-content">{{ content.degreeType }}</div>
      </div>
      <!-- <div class="edu-auto-col">
        <div class="edu-auto-label">专项计划：</div>
        <div class="edu-auto-content">{{ content.spcialPlan }}</div>
      </div> -->
    </div>
  </el-card>
</template>

<script>
export default {
    props: {
        content: {
            default: null,
        },
    },
    methods: {
        preview() {
            if(this.content.projId == 1){
              console.log(this.content.cultureId)
              this.$router.push({
                path: "/bclCultureTemplateView",
                query: {
                    projId: this.content.projId,
                    id: this.content.cultureId,
                    dataType: 2
                }
              });
            }else{
                let content = this.content || {};
                let schemeDetails =  {
                    projId: content.projId,
                    id: content.cultureId,
                    dataType: 2,
                    nameCN: "",
                    nameEN: ""
                }
               sessionStorage.setItem("schemeDetails",JSON.stringify(schemeDetails));
              this.$router.push({
                name: 'cultureTemplateView',
                params: {
                    projId: this.content.projId,
                    id: this.content.cultureId,
                    dataType: '2',
                },
              })
            }
        },
    },
}
</script>

<style lang="css">
</style>
